From 0bf3f5797cf3a9e045905fdd4c5adc3bb9fd4d82 Mon Sep 17 00:00:00 2001 From: =?utf8?q?=C3=98yvind=20Kol=C3=A5s?= Date: Tue, 30 Aug 2005 12:30:41 +0000 Subject: [PATCH] freeing of non babl allocated memory is fatal. --- ChangeLog | 5 +++++ babl/babl-memory.c | 3 ++- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index c9250cb..8836549 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2005-08-30 Øyvind Kolås + + * babl/babl-memory.c: (babl_free): freeing of non babl allocated + memory is fatal. + 2005-08-29 Øyvind Kolås * tests/types.c: added test that tests the symmetry of reference diff --git a/babl/babl-memory.c b/babl/babl-memory.c index b4fa769..811414e 100644 --- a/babl/babl-memory.c +++ b/babl/babl-memory.c @@ -138,7 +138,8 @@ babl_free (void *ptr) { if (!ptr) return; - assert(IS_BAI(ptr)); + if(!IS_BAI(ptr)) + babl_fatal ("memory not allocated by babl allocator"); functions_sanity (); free_f (BAI(ptr)); frees++; -- 2.30.2